1. Field of the Invention
The present invention relates generally to a method and apparatus for the detection of defects on the surface of an object and more particularly, to a method and apparatus suitable for use with a system that employs a video camera, the image signals of which are processed by a computer, to automatically detect defects on inspected objects.
2. Description of the Prior Art
It has become a common practice in recent years, to detect surface defects such as flaws, dirt, or the like, by photosensing the illuminated image of an object undergoing inspection by using a video camera, such as a CCD (charge coupled device) camera, a solid state photosensing element or the like. Generally, the video output signal of the camera is digitized and the photoelectric conversion signals from each of the pixels of the digitized video signal are processed to determine whether a surface defect exists. A comparison of the respective data values obtained to a preset threshold value is the method most generally utilized for determining the existence of a defect.
However, since the brightness contrast of the flaws or dirt varies across the surface of the inspected object, the conventional defect detection methods that operate by digitizing the contrast ratio on the picture screen, make it difficult to detect those defects that exhibit only slight contrast variation from the remaining un-flawed surface. In other words, detection is relatively simple when defects such as black dots, having great contrast variation from the background are sensed on the picture screen so that the difference in contrast data as compared to the background is large, but detection is difficult when surface flaws, or the like, exhibit only subtle contrast variation from the background. This problem is exacerbated when the flawed area is large, due to the subtle difference of its data value to the background.
Previous attempts to detect defects exhibiting only minor contrast variation from the background involve acknowledging the subtle difference in data value as a defect. However, such systems will also cause the sensing of slight indentations or lumps that produce slight intensity changes against the background to be determined as defects, though they may be representative of good product. Thus, it has proven difficult to accurately detect low contrast defects as representative of bad product. Consequently, the problem of a high good product rejection rate has not been solved.